﻿<?php
require_once 'includes/includes.php';
conexion();
?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="content-type" content="text/html; charset=utf-8"/>
<title><?php titulo(); ?></title>

<?php require_once 'includes/head.php'; ?>

<link rel="stylesheet" href="plugins/vSlider/css/vslider.css" />
<link rel="stylesheet" href="plugins/slideViewer/css/slideviwer.css" />

<script type="text/javascript" src="plugins/jquery.js" ></script>

<script type="text/javascript" src="plugins/vSlider/js/jquery.vslider.js" ></script>
<script src="plugins/slideViewer/sliderviewer.js" type="text/javascript"></script>
<script src="plugins/slideViewer/jquery-easing.js" type="text/javascript"></script>



 <script type="text/javascript">
	$(function(){
	$("#slide").vSlider({time:6000, 
		effect:9, 
		maskInduration:30, 
		maskOutduration:10,
		width:470,
		height:350
			
		});
	});
</script>

<script type="text/javascript">
	$(window).bind("load", function() {
	$("div#mygalone").slideView({
		toolTip: true, 
		ttOpacity: 0.5,
		easeFunc: "easeInOutSine",
		easeTime: 2200


		
		})
});
</script>


</head>

<body>
<div id="wrapper">

	<?php require_once 'includes/encabezado.php'; ?>
	<!-- end #header -->
	
	
	
		
		<div id="sidebarleft">				
			<?php require 'includes/sidebar.php'; ?>
		</div>
	
		<div id="content">
		
		<div class="bannernews">
			<img src="images/Presentaciones.png"/>
		</div>
		
			
		<?php 
		
		$newquery=mysql_query("SELECT id,title,summary FROM news WHERE is_published = 1 and created <= now() ORDER BY created limit 0,3");
		
		
		echo '<ul id="slide">';
		while ($rownews=mysql_fetch_array($newquery)){
					$id=$rownews['id'];
					$title=$rownews['title'];
					$summary=$rownews['summary'];
					$respfoto=mysql_query("select * from images where entry_id=$id");

					if(mysql_num_rows($respfoto)!=0){
								$rowimage= mysql_fetch_array($respfoto);
								$folder=$rowimage['folder']; //GET DATA FROM DB
								$foto=$rowimage['url'];
					}
					
					echo '<li>';
						echo  '<a href="new.php?id='.$id.'"><img src="'.$folder.$foto.'"  width="600" height="350" alt="" /></a><span> <div class="titlevSlider">'.$title.'</div>'.$summary.'</span>';
					echo '</li>';
				
		}
		echo '</ul>';			
			
				
		echo '<div style="clear: both;">&nbsp;</div>';
		echo '<div style="clear: both;">&nbsp;</div>';
		echo '<div style="clear: both;">&nbsp;</div>';	
			
			
		?>
		
		<div class="bannernews">
			<img src="images/galeria.png"/>
		</div>
		
		<!-- http://www.gcmingati.net/wordpress/wp-content/lab/jquery/imagestrip/imageslide-plugin.html -->
		<div id="mygalone" class="svw">
			<ul>
				<li><img alt=""  src="images_gallery/4.png"  width="470" height="350"/></li>
				<li><img alt=""  src="images_gallery/3.jpg"  width="470" height="350"/></li>
				<li><img alt=""  src="images_gallery/2.jpg"  width="470" height="350"/></li>
				<li><img alt=""  src="images_gallery/1.jpg"  width="470" height="350"/></li>
				<!-- eccetera -->
			</ul>
		</div>			
	
		
		</div>
		<!-- end #content -->
		
		<div id="sidebarright">		
		<?php
                                require_once 'includes/publicidades.php';
                ?>
                
		</div>
		<!-- end #sidebar -->
		
		
	
	
	<!-- end #page -->
</div>
<div style="clear: both;">&nbsp;</div>
	<div id="footer">
		<?php require_once 'includes/pie.php'; ?>
	</div>
	<!-- end #footer -->
</body>
</html>
